﻿using PluginAPI.Core.Attributes;
using PluginAPI.Enums;
using PluginAPI.Events;
using Utils;


namespace RoleCustom.Event
{
    /// <summary>
    /// NTF Private Event
    /// </summary>
    public class ChaosSpawnEvent
    {
        [PluginEvent(ServerEventType.PlayerSpawn)]
        public void OnNTFPrivateSpawn(PlayerSpawnEvent ev)
        {
            TimeCoroutine.Delay(0.5f, () =>
            {
                if (ev.Player.Team != PlayerRoles.Team.ChaosInsurgency) return;

                PlayerUtils.SetHP(ev.Player,
                    100,
                    100);
            });
        }
    }
}
